package highlighter.ast.impl;

import highlighter.visitor.IASTVisitor;

public class IfStmt extends Statement {

	private RelationalExpr relExpr;
	private Body thenBody;
	private Body elseBody;

	public IfStmt(RelationalExpr relExpr, Body thenBody, Body elseBody) {
		super();
		this.relExpr = relExpr;
		this.thenBody = thenBody;
		this.elseBody = elseBody;
	}

	public RelationalExpr getRelExpr() {
		return relExpr;
	}

	public Body getThenBody() {
		return thenBody;
	}

	public Body getElseBody() {
		return elseBody;
	}

	@Override
	public Object accept(IASTVisitor visitor) {
		return visitor.visit(this);
	}
}
